package com.itheima.health.mq;


import com.itheima.health.utils.sms.SmsUtils;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

import java.util.Map;

@Component
public class SmsSendMessage {

    @RabbitListener(queues = "health-queue")  //  持续监听 一旦发现  立刻 调用阿里云 发送短信
    public void send(Map map){
        System.out.println("------------短信发送成功----------");
//        SmsUtils.validUserTelephone((String)map.get("telephone"),(String)map.get("code"));
    }
}
